home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / edit / me_cd25.zip / MUTT2.ZIP / WINDOW.MUT < prev    next >
Text File  |  1992-11-09  |  711b  |  31 lines

  1. ;; Some window ops
  2. ;; C Durland    Public Domain
  3.  
  4. (defun
  5.   MAIN
  6.   {
  7.     (bind-to-key "grow-window"        'C-x^')
  8.     (bind-to-key "shrink-window"    "C-xC-z")
  9.   }
  10.   grow-window   { (window-height -1 (+ (window-height -1) (arg-prefix))) }
  11.   shrink-window { (window-height -1 (- (window-height -1) (arg-prefix))) }
  12.   shrink-window-to-dot { (window-height -1 (window-row -1)) }
  13. )
  14.  
  15. (include me2.h)
  16. (defun
  17.   change-window-size
  18.   {
  19.     (int w n old-size)
  20.  
  21.     (w (convert-to NUMBER (ask "window to change: ")))
  22.     (n (convert-to NUMBER (ask "new window size: ")))
  23.     (old-size (window-height w))
  24.  
  25.     (window-height w n)
  26.  
  27.     (msg "old size: " old-size 
  28.     "   new size: " (window-height w))
  29.   }
  30. )
  31.